c# list sort by property string

60

c# list sort by property string -

list.Sort((a, b) =>  a.StringProperty.CompareTo(b.StringProperty));

c# list sort by property string -

var sortedQuery = sampleList.OrderBy(x => x.MyProperty);

Comments

Submit
0 Comments